import request from '@/utils/request'

// 查询枪支许可证信息列表
export function listLicence(query) {
  return request({
    url: '/service/licence/list',
    method: 'get',
    params: query
  })
}

// 离职人员持枪证统计表
export function listQuitLicence(query) {  
  return request({    
    url: '/service/licence/quit/list',    
    method: 'get',    
    params: query  
  })
}

// 查询枪支许可证信息详细
export function getLicence(id) {
  return request({
    url: '/service/licence/' + id,
    method: 'get'
  })
}

// 新增枪支许可证信息
export function addLicence(data) {
  return request({
    url: '/service/licence',
    method: 'post',
    data: data
  })
}

// 修改枪支许可证信息
export function updateLicence(data) {
  return request({
    url: '/service/licence',
    method: 'put',
    data: data
  })
}

// 删除枪支许可证信息
export function delLicence(id) {
  return request({
    url: '/service/licence/' + id,
    method: 'delete'
  })
}
